package com.csdj.t309springboot.controller;
import com.csdj.t309springboot.entity.RespPageBean;
import com.csdj.t309springboot.service.EmployeeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @description:
 * @author: Leo
 * @createDate: 2020/2/1
 * @version: 1.0
 */
@RestController
@RequestMapping("/emp/basic")
public class EmpBasicController
{
    @Resource
    EmployeeService employeeService;
    @GetMapping("/page")
    public RespPageBean getEmpByPage(@RequestParam(defaultValue = "1") Integer page,
                                     @RequestParam(defaultValue = "10") Integer size){
        return employeeService.getEmpByPage(page,size);
    }
}

